package rule03;

/**
 * @author ChangLiang
 * @date 2020/3/16
 */
public final class SingletonObject3 {

    private static SingletonObject3 instance;

    private SingletonObject3(){}

    public synchronized static SingletonObject3 getInstance() {
        if (null == instance) {
            return new SingletonObject3();
        }
        return SingletonObject3.instance;
    }
}
